package com.woniu.controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
@RequestMapping("/test")
public class TestController {
    @RequestMapping("/query")
    public String query(Model model) {
        model.addAttribute("content", "这是后端查询出来的数据");
        // 此处写templates下面html视图的名称
        return "index";
    }
}
